void addint_one_q(double *uf, double *uc, double *res, int nf)
/*Does coarse-to-fine interpolation and adds result to uf . nf is the fine-grid dimension. The coarse-grid solution is input as uc[1..nc], where nc = (nf+1)/2. The fine-grid solution
  is returned in uf[1..nf] . res[1..nf] is used for temporary storage.*/
{
  void interp_one_q(double *uf, double *uc, int nf);
    int i;

   interp_one_q(res,uc,nf);
    for (i=1;i<=nf;i++)
         uf[i]+=res[i];
}
